package com.wmzdq.photocenter.config;

import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.context.support.ReloadableResourceBundleMessageSource;

@Configuration
//@ComponentScan(basePackages="com.wmzdq.controller",useDefaultFilters=false,includeFilters={@ComponentScan.Filter(type=FilterType.ANNOTATION,value=Controller.class)})
public class AppConfig {
    
    /*@Autowired
    FastJsonHttpMessageConverter fastConverter;*/

    //提供给springmvc的国际化使用�?messageSource,localResolver配置在mvcConfig.java�?
    @Bean(name="messageSource")
    public ReloadableResourceBundleMessageSource messageSource(){
        ReloadableResourceBundleMessageSource messageSource=new ReloadableResourceBundleMessageSource();
        messageSource.setDefaultEncoding("UTF-8");
        messageSource.setBasename("classpath:messages");
        return messageSource;
    }
    
   
}
